﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Web;
using AppShare.Data.Models;

namespace AppShare.Web
{
    public sealed partial class SubmitData
    {
        [Key]
        public string SHA1 { get; set; }
        [Key]
        public string eMuleHash { get; set; }
        [Key]
        public string FileSize { get; set; }

        public SubmitFile ToSubmitFile()
        {
            return new SubmitFile()
            {
                SHA1 = SHA1,
                FileID = eMuleHash,
                FileSize = FileSize,
                SubmitTime = DateTime.Now,
            };
        }
    }
}